package com.example.demo.base;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 请求体包装对象
 */
public class ReqParamBody<T> implements Serializable {

	private static final long serialVersionUID = 6306747792003091002L;
	private String sign;
    private Long timestamp;
    private String sysCode;
    private String version;
    private String token;

    @Valid
    @NotNull(message = "业务数据不能为空")
    private T data;

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }

    public String getSign() {
        return sign;
    }

    public void setSign(String sign) {
        this.sign = sign;
    }

    public Long getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(Long timestamp) {
        this.timestamp = timestamp;
    }

    public String getSysCode() {
        return sysCode;
    }

    public void setSysCode(String sysCode) {
        this.sysCode = sysCode;
    }


    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

	@Override
	public String toString() {
		return "ReqParamBody [sign=" + sign + ", timestamp=" + timestamp + ", sysCode=" + sysCode + ", version="
				+ version + ", token=" + token + ", data=" + data + "]";
	}
    
    
}
